<?php
/*
 * @Author: wanzhengxin
 * @Date: 2021-04-01 21:58:34
 */


namespace app\index\controller;
use app\index\service\OrderService;

class Order extends Base
{
    public function callBack()
    {
        //接受微信回调的参数
        $xmlData = file_get_contents('php://input');
        $data = json_decode(json_encode(simplexml_load_string($xmlData, 'SimpleXMLElement', LIBXML_NOCDATA)), true);
        var_dump($data);
    }
    /**
     * 订单支付金额money，onenid
     */
    public function pay()
    {
        $data = $this->request->param();
        $orderService = new OrderService();
        return $orderService->pay($data);
    }
    public function push1()
    {
        $data = $this->request->param();
        $orderService = new OrderService();
        return $orderService->push1($data);
    }
    public function push2()
    {
        $data = $this->request->param();
        $orderService = new OrderService();
        return $orderService->push2($data);
    }
}